package com.group.eams.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.group.eams.pojo.dto.AssetDetailQueryDto;
import com.group.eams.pojo.dto.AssetReportQueryDto;
import com.group.eams.pojo.dto.RepairRecordQueryDto;
import com.group.eams.pojo.entity.AssetReport;
import com.group.eams.pojo.entity.MaintenApply;
import com.group.eams.pojo.entity.RepairRecord;
import com.group.eams.pojo.entity.RepairRecord;
import com.group.eams.pojo.vo.AssetReportListVo;
import com.group.eams.pojo.vo.FixedAssetListVo;
import com.group.eams.pojo.vo.RepairRecordListVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author 恩哲欣
* @description 针对表【repair_record(维修记录)】的数据库操作Mapper
* @createDate 2024-10-29 16:09:34
* @Entity com.group.eams.pojo.entity.RepairRecord
*/
public interface RepairRecordMapper extends BaseMapper<RepairRecord> {

    /**
     * 分页条件查询
     * @param page 分页条件
     * @param repairRecordQueryDto 查询条件
     * @return 页数数据+总记录数
     */
    Page<RepairRecordListVo> findRepairRecordByPage(Page<RepairRecord> page,
                                                    @Param("repairRecordQueryDto") RepairRecordQueryDto repairRecordQueryDto);


    /**
     * 分页条件查询
     * @param page 分页条件
     * @return 页数数据+总记录数
     */
    Page<FixedAssetListVo> findDetailByPage(Page<RepairRecord> page, @Param("assetDetailQueryDto") AssetDetailQueryDto assetDetailQueryDto);

    /**
     * 根据维修记录单号查询
     * @param repairRecordNum
     */
    List<RepairRecord> findByRepairRecordNum(String repairRecordNum);

}